<template>
  <div class="about">
    <h1>This is an about page</h1>
    <div>
      <h1>User ID: {{ id }}</h1>
      <h2>User Name: {{ name }}</h2>
    </div>
    <el-button type="primary" @click="goHomePage">跳转到Home页</el-button>
    <el-button type="primary" @click="goFilePage">跳转到文件页</el-button>
    <el-button type="primary" @click="goFilePage2">跳转到文件页2</el-button>
<!--    <el-button type="primary" @click="goHomePage">主要按钮</el-button>-->
<!--    <el-button type="primary" @click="goHomePage">主要按钮</el-button>-->
<!--    <el-button type="primary" @click="goHomePage">主要按钮</el-button>-->
  </div>
</template>

<script>
export default {
  name: 'AboutView',
  props: ['id', 'name'],
  data(){
    return{
      user:{},
      dataList:[],
      msg:"good",
    }
  },
  created() {
    // this.user = this.$route.params;
    // console.log("name",this.user.name);
    // console.log("id",this.user.id);
    this.initRequest();
  },
  methods:{
    goHomePage(){
      this.$router.push({
        path:"/",
        query:{
          id:12,
          name:"赵奢"
        }
      })
    },
    goFilePage(){
      this.$router.push({
        path:"/file",
        query:{
          id:12,
          name:"赵奢"
        }
      })
    },
    goFilePage2(){
      this.$router.push({
        path:"/file2",
        query:{
          id:12,
          name:"赵奢"
        }
      })
    },
    initRequest(){
    }
  }
}
</script>